package pri.zxx.webdemo.config;

import java.io.ByteArrayOutputStream;
import java.io.PrintStream;

/**
 * @author Twilight
 * @desc
 * @createTime 2020-05-16-18:32
 */
public class ExPrint {

    /**
     * 打印异常栈
     */
    public static String print(Exception e) {
        ByteArrayOutputStream baos = new ByteArrayOutputStream();
        e.printStackTrace(new PrintStream(baos));
        return baos.toString();
    }
}
